﻿using System.Web.Http;
using System.Web.Mvc;

namespace Jizsoft.WebApp.Areas.ASMS
{
    public class ASMSAreaRegistration : AreaRegistration
    {
        public override string AreaName
        {
            get
            {
                return "ASMS";
            }
        }

        public override void RegisterArea(AreaRegistrationContext context)
        {
            context.MapRoute(
                "ASMS_default",
                "ASMS/{controller}/{action}/{id}",
                new { controller = "ASMS", action = "Index", id = UrlParameter.Optional },
                new string[] { "Sunboxsoft.ASMS.Web.Controllers" }
            );
            System.Web.Http.GlobalConfiguration.Configuration.Routes.MapHttpRoute(
                name: "ASMS_Api",
                routeTemplate: "api/ASMS/{controller}/{action}/{id}",
                defaults: new { id = RouteParameter.Optional }
            );
        }
    }
}
